package mystudy.utils;

import mystudy.po.User;

/**
 * @Description
 * @Author LWW
 * @Date 2022/4/8 13:28
 */
public class userHolder {
	private static final ThreadLocal<User> tl = new ThreadLocal<>();

	public static void saveUser(User userId){
		tl.set(userId);
	}

	public static User getUser(){
		return tl.get();
	}

	public static void removeUser(){
		tl.remove();
	}
}
